package novel.front.novellist.dao;

import novel.front.novellist.entity.LiebaoApp;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface LiebaoAppMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(LiebaoApp record);

    int insertSelective(LiebaoApp record);

    LiebaoApp selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(LiebaoApp record);

    int updateByPrimaryKey(LiebaoApp record);

    List<LiebaoApp> searchApp(LiebaoApp liebaoApp);

    List<LiebaoApp> getListByCategoryId(@Param("categoryId") int categoryId);

    List<Map<String, String>> getTagPercent();

    List<LiebaoApp> getListDesc(@Param("offset") int offset, @Param("limit") int limit);

    List<LiebaoApp> getListFromTo(@Param("offset") int offset, @Param("limit") int limit);

    List<LiebaoApp> getListRandom();

    LiebaoApp getAppByName(@Param("appName") String appName);
}
